package com.xcc.factorypattern.demo03;

/**
 * @Description: ChicagoPizzaStore
 * @Author xiechuang
 * @Date 2022/9/3
 */
public class ChicagoPizzaStore extends PizzaStore{

    @Override
    Pizza createPizza(String type) {
        if ("cheese".equals(type)) {
            return new ChicagoStyleCheesePizza();
        } else if ("pepperoni".equals(type)) {
            return new ChicagoStylePepperoniPizza();
        } else if ("clam".equals(type)) {
            return new ChicagoStyleClamPizza();
        } else if ("veggie".equals(type)){
            return new ChicagoStyleVeggiePizza();
        }
        return null;
    }

}
